home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CU Amiga Super CD-ROM 1
/
CU Amiga Magazine CD-ROM Special Edition (1995)(EMAP Images)(GB)[Issue 1995-11].iso
/
Aminet
/
biz
/
dbase
/
AFile_v403.lha
/
AFile
/
Example
/
Disks.mask
< prev
next >
Wrap
Text File
|
1995-02-11
|
1KB
|
59 lines
/*
* This is a sample input mask for AFile
* It demonstrates the $MASK, $MENU, $PRINT and $PRINTFMT specifications
*
* $MASK Disks.pic
** Field XPos YPos Width AREXX? Message
* ARTIST 246 58 - - Artist or band
* ALBUM 246 74 - - Album's name
* YEAR 320 35 - CHECK Released year (with century)
* DURATION 234 106 - - Duration in minutes
* PURCHASE 320 160 - CHECK Purchase date
* CD 315 172 - - Set for CD, cleared for K7
* STYLE 275 140 - - Kind of music
* $END
*
* $MENU
** Item Args? Script
* Stats - DisksStats.rexx
* $END
*
* $PRINT DisksPrint.rexx
*
* The above print script produce the same output that the following specification:
** $PRINTFMT %1, %2 (%3)\n
* Try both of them (not at the same time, as told in the doc !)
*/
OPTIONS RESULTS
PARSE ARG Field Value
Value = STRIP( Value )
SAY Field
SAY Value
/*
* Verifies that YEAR is in the YYYY format
*/
IF Field = 'YEAR' THEN DO
IF LENGTH( Value ) = 4 THEN EXIT 0
EXIT 10
END
/*
* Verifies that PURCHASE date is at least greater than released YEAR
* We get PURCHASE value in the YYYYDDMM format
* The YEAR field is in the YYYY format
*/
IF Field = 'PURCHASE' THEN DO
ADDRESS "AFile_rexx"
"GETFIELD YEAR"
IF RESULT <= LEFT( Value , 4 ) THEN EXIT 0
EXIT 10
END
EXIT 10